import Axios from './axios'

Axios.interceptors.request.use((config)=>{
    config.headers.token = 'asadas'
    return config;
});


// Axios.interceptors.response.use(res=>{
//     return res.data;
// });


(async ()=>{

    // Axios.default.transformRequest = config => {
    //     config.headers.token = 'token str';
    //     return config
    // }

    let r = await Axios('/data/test.json',{

        headers:{
            a:1
        },

        
    });

    console.log(r);
})()


// Axios.get('/1.txt');
// Axios.get({url:'/2.txt',headers:{a:1}});
// Axios.get('/3.txt',{headers:{b:2,token:'token'}})

// Axios.delete('/1.txt');
// Axios.delete({url:'/2.txt',headers:{a:1}});
// Axios.delete('/3.txt',{headers:{b:2,token:'token'}})

// Axios.post('/1.php')
// Axios.post('/2.php',{a:1,b:2})
// Axios.post('/3.php',{a:1,b:2},{headers:{a:1}})

